package ssh.shop.service.impl;

import org.springframework.stereotype.Service;
import ssh.shop.dao.UserDao;
import ssh.shop.entity.ReturnEmployee;
import ssh.shop.entity.User;
import ssh.shop.service.UserService;

import java.util.List;

@Service("userService")
public class UserServiceImpl extends BaseServiceImpl<User> implements UserService {



    @Override
    public User login(User user) {
        return userDao.login(user);
    }

    @Override
    public void del(String id) {
       userDao.delete(Integer.parseInt(id));
    }

    @Override
    public List<User> userList() {
        return userDao.userList();
    }

    @Override
    public User getUserById(String id) {
        return userDao.getUser(id);
    }


    @Override
    public List<ReturnEmployee> userListB() {
        return userDao.userListB();
    }

    @Override
    public List<Object[]> userListObjec() {
        return userDao.userListObjec();
    }

    @Override
    public void queryUser(User user) {
        userDao.queryUser(user);
    }

    @Override
    public void saveUser(User user) {
        userDao.saveUser(user);
    }

    @Override
    public void delUser(User user) {
        userDao.delUser(user);
    }
}
